#ifndef TABBARBUTTON_H
#define TABBARBUTTON_H
#include <QPushButton>
#include "widgetbackgrounddrawer.h"

namespace ExecTerminalImplNS 
{
    class TopTabBar;
    class TabBarButton: public QPushButton
    {
    public:
        enum Position 
        {
            LeftPosition,
            RightPosition
        };
    public:
        TabBarButton(QWidget * parent, Position position);
        Position position()const;

    protected:
        void enterEvent(QEvent *);
        void leaveEvent(QEvent *);
        void paintEvent(QPaintEvent *);

    protected:
        virtual void drawPixmap(QPainter * p);

    private:
        WidgetBackgroundDrawer theBackgroundDrawer;
        bool theMouseOver;
        Position thePosition;
    };
}

#endif

